<div id="id_{{ field_name }}" class="tag_widget">
  <ul>
  {% for tag in initial_tags %}
    <li class="output">
      <input type="hidden" name="{{ field_name }}" value="{{ tag }}" />
      {% if tag.get_absolute_url %}
      <a href="{{ tag.get_absolute_url }}" rel="tag">{{ tag }}</a>
      {% else %}
      {{ tag }}
      {% endif %}
      <img src="{{ style_url }}delete.png" alt="[-]" onclick="deleteTag(this);" />  
    </li>
  {% endfor %}
    <li class="input">
      <input type="text" name="{{ field_name }}" class="suggest_tag" autocomplete="off" maxlength="{{ maxlength }}" />
      <img src="{{ style_url }}delete.png" alt="[-]" title="" onclick="deleteTag(this);" />
  </ul>
  <p><img src="{{ style_url }}add.png" alt="[+]" title="" onclick="addTag(this.parentNode.parentNode);" /></p>
  <ul class="suggest tag" style="display:none">
    {% for tag in tags %}
    <li>{{ tag }}</li>
    {% endfor %}
  </ul>
  {{ debug }}
</div>

<script type="text/javascript" src="{{ js_url }}tags.js"></script>
<script type="text/javascript">
  addEvent(window, 'load', function() {initTagWidget(document.getElementById('id_{{ field_name }}'));});
</script>